const container = document.getElementById('container');
const text = document.getElementById('text');

const totalTime = 7500;
const breathTime = (totalTime / 5) * 2;
const holdTime = totalTime / 5;

function breathAnimation() {
    text.innerHTML = 'Breath In!';
    container.className = 'container grow';

    setTimeout(_ => {
        text.innerText = 'Hold';

        setTimeout(_ => {
            text.innerText = 'Breath Out!';
            container.className = 'container shrink';
        }, holdTime)
    }, breathTime);
}

setInterval(breathAnimation, totalTime);